package com.yanqu.road.entity.activity.peakstronghold;

import com.yanqu.road.entity.DataObject;
import com.yanqu.road.entity.FieldTypeAnnotation;

import java.util.ArrayList;
import java.util.LinkedList;
import java.util.List;

// 据点战联盟缓存数据
@FieldTypeAnnotation(tableName = "t_u_peak_stronghold_upload_mark", autoSave = true)
public class PeakStrongholdUploadMarkData extends DataObject {
    @FieldTypeAnnotation(select = true, update = true, desc = "活动id", isIndex = true)
    private int activityId;
    @FieldTypeAnnotation(select = true, update = true, desc = "商会分组", isIndex = true)
    private int unionGroup;
    @FieldTypeAnnotation(desc = "实际跑的回合数")
    private int round;
    @FieldTypeAnnotation(desc = "等待上传赚力的玩家")
    private LinkedList<Long> waitUploadAbilityUsers = new LinkedList<>();
    @FieldTypeAnnotation(desc = "等待上传防守数据的玩家")
    private LinkedList<Long> waitUploadDefendUsers = new LinkedList<>();
    @FieldTypeAnnotation(desc = "淘汰赛资格商会列表")
    private List<String> unionIds = new ArrayList<>();
    @FieldTypeAnnotation(desc = "已淘汰商会列表")
    private List<String> outUnionIds = new ArrayList<>();

    public PeakStrongholdUploadMarkData() {
    }

    public PeakStrongholdUploadMarkData(int activityId, int unionGroup) {
        this.activityId = activityId;
        this.unionGroup = unionGroup;
        setInsertOption();
    }

    public int getActivityId() {
        return activityId;
    }

    public void setActivityId(int activityId) {
        this.activityId = activityId;
    }

    public int getRound() {
        return round;
    }

    public void setRound(int round) {
        if (this.round != round) {
            this.round = round;
            setUpdateOption();
        }
    }

    public LinkedList<Long> getWaitUploadAbilityUsers() {
        return waitUploadAbilityUsers;
    }

    public void setWaitUploadAbilityUsers(LinkedList<Long> waitUploadAbilityUsers) {
        this.waitUploadAbilityUsers = waitUploadAbilityUsers;
    }

    public LinkedList<Long> getWaitUploadDefendUsers() {
        return waitUploadDefendUsers;
    }

    public void setWaitUploadDefendUsers(LinkedList<Long> waitUploadDefendUsers) {
        this.waitUploadDefendUsers = waitUploadDefendUsers;
    }

    public List<String> getUnionIds() {
        return unionIds;
    }

    public void setUnionIds(List<String> unionIds) {
        this.unionIds = unionIds;
    }

    public int getUnionGroup() {
        return unionGroup;
    }

    public void setUnionGroup(int unionGroup) {
        this.unionGroup = unionGroup;
    }

    public List<String> getOutUnionIds() {
        return outUnionIds;
    }

    public void setOutUnionIds(List<String> outUnionIds) {
        this.outUnionIds = outUnionIds;
        setUpdateOption();
    }
}
